<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>世奇广告</title>
<link href="css/default.css" rel="stylesheet" type="text/css" />
<link href="css/uploadify.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="scripts/jquery-1.3.2.min.js"></script>
<script type="text/javascript" src="scripts/swfobject.js"></script>
<script type="text/javascript" src="scripts/jquery.uploadify.v2.1.0.js"></script>
<script type="text/javascript" src="scripts/jquery.alerts.js"></script>
<script type="text/javascript" src="scripts/jquery.form.js"></script>
<script type="text/javascript">
$(document).ready(function() {
	var nowpic = new Array();
	var nowname = new Array();
	$("#fileUploadgrowl").uploadify({
		'uploader'       : 'scripts/uploadify.swf',
		'script'         : 'scripts/uploadify.php',
		'cancelImg'      : 'cancel.png',
		'folder'         : 'uploads',
		'urls'         : location.href,
		'queueID'        : 'fileQueue',
		'fileDesc'		 : '世奇广告文件(*.jpg;*.gif;*.swf;*.png;*.zip;*.html)',
		'fileExt'		 : '*.jpg;*.gif;*.swf;*.png;*.zip;*.html',
		'simUploadLimit' : 2,
		'queueSizeLimit' : 5,
		'multi'          : true,
		onComplete: function (a, b ,c, d, e) {
			var size = Math.round(c.size/1024);
			//alert(c.name);
			//alert(d);
			nowpic.push(d);
			nowname.push(c.name);
			//$("#inatt").append('<tr><td rowspan="4" valign="top">No.12412<br>1212.jpj</td><td>是否动画</td><td><label><input type="checkbox" name="2" id="2" /></label></td></tr><tr><td>标签</td><td><input type="text" name="12" id="12" /></td></tr><tr><td>发布时间</td><td><input name="122" type="text" id="122" size="9" />-<input name="1222" type="text" id="1222" size="9" /></td></tr><tr><td>广告主</td><td><label><select name="22" id="22"></select></label></td></tr>');
		},
		onAllComplete:function (a, b){
			jQuery('#fileBar').hide();
			
			jAlert('<input type="text" value="Hello HTML" name="message"/><table width="100%" border="0" cellspacing="0" cellpadding="0" id="inatt"></table><div id="popup_panel"><input id="popup_ok" type="submit" value="OK" /></div><div id="htmlExampleTarget"></div>','修改广告属性');
			var i=0;
			while(i<nowpic.length){
			/*判断是否已经存在数据库*/
			if(nowpic[i]!='0'){
				$("#inatt").append('<tr><td rowspan="4" valign="top">No.'+nowpic[i]+'<br>'+nowname[i]+'</td><td>是否动画</td><td><label><input type="checkbox" value="1" name="animation_'+nowpic[i]+'" id="animation_'+nowpic[i]+'" /></label></td></tr><tr><td>标签</td><td><input type="text" name="tags_'+nowpic[i]+'" id="tags_'+nowpic[i]+'" /></td></tr><tr><td>发布时间</td><td><input name="start_'+nowpic[i]+'" type="text" id="start_'+nowpic[i]+'" size="9" />-<input name="ends_'+nowpic[i]+'" type="text" id="ends_'+nowpic[i]+'" size="9" /></td></tr><tr><td>广告主</td><td><label><select name="host_'+nowpic[i]+'" id="host_'+nowpic[i]+'"><option value="one" selected="selected">One</option><option value="two">Two</option><option value="three">Three</option></select></label></td></tr>');
			}
			i++;
			}
//			if(nowpic[0]){
//				alert(nowpic[0]);
//				alert(nowpic.length);
//			}
			
			nowpic.length=0;
			nowname.length=0;
		}
	});
});
</script>
<style type="text/css"> 
<!-- 

--> 
</style><!--[if IE]>
<style type="text/css"> 
/* 请将所有版本的 IE 的 css 修复放在这个条件注释中 */
.twoColLiqLtHdr #sidebar1 { padding-top: 30px; }
.twoColLiqLtHdr #mainContent { zoom: 1; padding-top: 15px; }
/* 上面的专用 zoom 属性为 IE 提供避免错误所需的 hasLayout */
</style>
<![endif]--></head>

<body class="twoColLiqLtHdr">

<div id="container"> 
  <div id="header">
	<h1>世奇广告</h1>
	<!-- end #header -->
  </div>
  
  <div id="sidebar1">
<h3>使用帮助</h3>
<ul>
<li>1.浏览</li>
<li>2.导入</li>
<li>3.搜索</li>
<li>4.下载</li>
<li>5.日志 </li>
</ul>
  <!-- end #sidebar1 --></div>
  <div id="mainContent">
<!--1-->
<h1>浏览</h1>
<div>翻页</div>
<!--2-->
<h1>导入<small>(最多5项)</small></h1>
<div id="fileUploadgrowl">抱歉，脚本遇到错误！</div>
<div id="fileQueue"></div>
<p id="fileBar" style="display:none"><a href="javascript:$('#fileUploadgrowl').uploadifyUpload()">开始上传</a> | <a href="javascript:jQuery('#fileUploadgrowl').uploadifyClearQueue()">清空</a></p>
<!--3-->
<h1>搜索</h1>
<div>提交</div>
<!--4-->
<h1>下载</h1>
<div>使用迅雷</div>
<!--5-->
<h1>日志</h1>
<div>查看，发邮件，备份</div>
<p/>
	<!-- end #mainContent --></div>
	<!-- 这个用于清除浮动的元素应当紧跟 #mainContent div 之后，以便强制 #container div 包含所有的子浮动 --><br class="clearfloat" />
  <div id="footer">
<p>&copy;2009 世奇广告</p>
  <!-- end #footer --></div>
<!-- end #container --></div>
</body>
</html>